package co.uniandes.pmc.gui;

import android.app.Activity;
import android.content.Context;
import android.content.Intent;
import android.location.Location;
import android.location.LocationListener;
import android.location.LocationManager;
import android.os.Bundle;
import android.view.View;
import android.widget.Button;
import android.widget.Toast;

public class PantallaPrincipal extends Activity {
    /** Called when the activity is first created. */
    @Override
    public void onCreate(Bundle savedInstanceState) {
        super.onCreate(savedInstanceState);
        setContentView(R.layout.main);
        
        final Button botonBuscar =(Button) findViewById(R.id.boton_buscar);
        botonBuscar.setOnClickListener(new View.OnClickListener() 
        {
			
			@Override
			public void onClick(View v) 
			{
				Intent intent = new Intent(PantallaPrincipal.this,PantallaSeleccionarIngreso.class);
				startActivity(intent);
				
			}
		});
        
        final Button botonCalificar =(Button) findViewById(R.id.boton_calificar);
        botonCalificar.setOnClickListener(new View.OnClickListener() 
        {
			
			@Override
			public void onClick(View v) 
			{
				
				
				Intent intent = new Intent(PantallaPrincipal.this,PantallaLogin.class);
				startActivity(intent);
				
			}
		});
        
//        LocationManager mlocManager = (LocationManager)getSystemService(Context.LOCATION_SERVICE);
//
//        LocationListener mlocListener = new MyLocationListener();
//
//
//        mlocManager.requestLocationUpdates( LocationManager.GPS_PROVIDER, 0, 0, mlocListener);


    }
        
//    public class MyLocationListener implements LocationListener
//
//    {
//        
//    public void onLocationChanged(Location loc)
//
//    {
//
//    loc.getLatitude();
//
//    loc.getLongitude();
//
//    String Text = "My current location is: Latitud = " + loc.getLatitude() +" Longitud = " + loc.getLongitude();
//
//
//    Toast.makeText( getApplicationContext(),Text,Toast.LENGTH_SHORT).show();
//
//    }
//
//	@Override
//	public void onProviderDisabled(String arg0) {
//		// TODO Auto-generated method stub
//		
//	}
//
//	@Override
//	public void onProviderEnabled(String provider) {
//		// TODO Auto-generated method stub
//		
//	}
//
//	@Override
//	public void onStatusChanged(String provider, int status, Bundle extras) {
//		// TODO Auto-generated method stub
//		
//	}
//
//
//  
//    
//        
//    }   
    
    
    
    
}